package com.http;

import com.richapp.launcher.ui.model.IpLocationModel;
import com.richapp.launcher.ui.model.PmModel;
import com.richapp.launcher.ui.model.WeatherModel;

import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.Query;
import rx.Observable;

/**
 * Created by wangwei on 2017/4/7.
 */

public interface IpHttpService {
    @POST("v3/ip")
    Observable<IpLocationModel> getIpLocation(@Query("key") String key);

    @GET("v5/now")
    Observable<WeatherModel> getWheather(@Query("key") String key, @Query("city") String city);

    /**
     *http://www.help.bj.cn/apis/aqi/?id=杭州
     * @return
     */
    @GET("apis/aqi/")
    Observable<PmModel> getPm25(@Query("id") String id );
}
